{* Smarty *}
{*debug*}
<div>{$title}</div>
{literal}
<script language="javascript" type="text/javascript" src="/js/datetimepicker.js"></script>
<script language=javascript>
<!--
        function popUp(url)
        {
                        var w = window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no,width=810,height=510,screenX='+(window.width)+',screenY='+(window.height)+',top='+(screen.height/4)+',left='+(screen.width/4));
        }
        
-->
</script>

{/literal}
<br/>
{if !isne($visible_print)}
<div>
<form method="POST" action="{$url}">
<input type="hidden" name="action" value="doApplyDates" />
<table>
        <tr>
                <td>
                        Start Date:&nbsp;<input type="Text" id="startDate" name="startDate" maxlength="25" size="25" style="width:115px;" value="{$start_date}"/>
                        <a href="javascript:NewCal('startDate','ddmmmyyyy',true,24)"><img src="/img/cal.gif" width="16" height="16" border="0" alt="Pick a date"></a>
                </td>
                <td>
                        End Date:&nbsp;<input type="Text" id="endDate" name="endDate" maxlength="25" size="25" style="width:115px;" value="{$end_date}"/>
                        <a href="javascript:NewCal('endDate','ddmmmyyyy',true,24)"><img src="/img/cal.gif" width="16" height="16" border="0" alt="Pick a date"></a>
                </td>
                <td>
                        <input type="submit" value="Apply dates" class="button"/>
                </td>
                
        </tr>
</table>
</form>
</div>
{/if}
<div>
<br/>
{$productlist1}
{*
<br/><br/>
{$productlist2}
<br/><br/>
*}
<div> 
        <table>
                <tr class="light">
                {if isne($start_date)}<td>From: {$start_date}</td>{/if}{if isne($end_date)}<td>To: {$end_date}</td>{/if}<td>Total items: {if $total_items > 0}{$total_items}{else}0{/if}</td><td>Total price: ${if $total_price > 0}{$total_price}{else}0{/if}</td>
                </tr>
        </table>
</div>
<br/>
{if !isne($visible_print)}
<div>
<input type='button' value='Print' class="button" onclick="popUp('{$print_url}')"/>
</div>
{/if}

